import { Button, Dropdown, Input, Space } from 'antd'
import { PlusOutlined, FolderAddOutlined } from '@ant-design/icons';
import FolderMenu from './FolderMenu';
import './index.less'

export default function FolderSidebar() {

    return (
        <div className='floder-sidebar'  >
            <Space style={{ padding: '10px' }}>
                <Button
                    icon={<PlusOutlined />}
                    type='primary'
                >
                    新增
                </Button>
                <Dropdown
                    menu={{
                        items: [
                            {
                                key: 'new_macro_folder',
                                label: '新建文件夹',
                                onClick: () => {

                                }
                            },
                            {
                                key: 'import_json',
                                label: '导入JSON或ZIP',
                                onClick: () => {

                                }
                            }
                        ]
                    }}
                    trigger={['click']}
                >
                    <Button shape="circle"
                        icon={<FolderAddOutlined />}
                    >
                    </Button>
                </Dropdown>
                <Input.Search
                    placeholder="搜索脚本"
                    allowClear
                />
            </Space>
            <FolderMenu />
        </div>
    )
}